package hc.bre.cmn.struct

import com.fasterxml.jackson.annotation.JsonInclude

@groovy.transform.CompileStatic
@groovy.transform.ToString(includeNames=true,includePackage=false)
abstract class DataStruct {
	static public final String rresultToken ='_rresult_';

	int maxid;
	DataStructItem root;

	DataStruct() {
		DataStructItem item;
		item = new DataStructItem();
		item.id = ++maxid;
		item.code = rresultToken;
		item.name = '全部';
		item.type = 'object';
		root = item;
		root.list=[];
	};

	public String accessRouteOf(int id) {
		return root.accessRouteOf(id);
	};

}
